Design patterns are also used to increase the reusability as rup advocated . the abstract factory , observer and iterator patterns is introduced Rup过程鼓励复用,设计过程中使用很多设计模式来增加复用性,如抽象工厂、观察者模式和迭代器模式等。
In object-oriented programming, the iterator pattern is a design pattern in which an iterator is used to traverse a container and access the container's elements. The iterator pattern decouples algorithms from containers; in some cases, algorithms are necessarily container-specific and thus cannot be decoupled.